package util

import (
	"crypto/hmac"
	"crypto/md5"
	"encoding/hex"
)

func Hmac(key, data string) string {
	hm := hmac.New(md5.New, []byte(key))
	hm.Write([]byte(data))
	return hex.EncodeToString(hm.Sum([]byte("")))
}
